def savebuffer():
    ...